package com.ruoyi.walmart.service.items.impl;

import com.ruoyi.walmart.domain.Items.Items;
import com.ruoyi.walmart.domain.Items.ReportItem;
import com.ruoyi.walmart.domain.Items.VoItems;
import com.ruoyi.walmart.domain.QuerySummary;
import com.ruoyi.walmart.mapper.Items.ItemsMapper;
import com.ruoyi.walmart.service.items.ItemsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ItemsServiceImpl implements ItemsService {
    @Autowired
    private ItemsMapper itemsMapper;
    @Override
    public int itemsInsertList(List<Items> itemsList) {
        return itemsMapper.itemsInsertList(itemsList);
    }
    @Override
    public int itemsBatchUpdate(List<Items> itemsList) {
        return itemsMapper.itemsBatchUpdate(itemsList);
    }
    @Override
    public List<Items> selectItemsList(VoItems items) {
        return itemsMapper.selectItemsList(items);
    }

    @Override
    public List<Items> selectItemsPair(VoItems items) {
        return itemsMapper.selectItemsPair(items);
    }

    @Override
    public int deleteItemsByAuthId(Long authId) {
        return itemsMapper.deleteItemsByAuthId(authId);
    }

    /** 更新链接商品的imageUrl，itemId */
    @Override
    public int updateItemsList(List<ReportItem> reportItemList) {
        return itemsMapper.updateItemsList(reportItemList);
    }
    /**
     * walmart汇总链接列表
     * @return
     */
    @Override
    public QuerySummary getItemsSummary(QuerySummary itemsSummary) {
        return itemsMapper.getItemsSummary(itemsSummary);
    }
    /**
     * 查询当前店铺walmart链接列表
     * @return
     */
    @Override
    public List<Items> selectItemsByAuthId(Long authId) {
        return itemsMapper.selectItemsByAuthId(authId);
    }


}
